package pri.ydy.eduorder.client;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import pri.ydy.commonUtils.ordervo.CourseInfoVoOrder;

/**
 * @Description:
 * @Author: 叶栋永
 * @CreateTime: 2021/2/7
 * @Company:
 * 创建接口,指明要调用哪个服务和那个接口
 */
@Component
@FeignClient("service-edu")//指明调用服务
public interface EduClient {
    //根据课程id获得课程信息
    @PostMapping("/eduservice/coursefront/getCourseInfoOrder/{id}")//完整路径
    public CourseInfoVoOrder getCourseInfoOrder(@PathVariable("id") String id); //做远程调用时@PathVariable必须加参数
}
